package net.xumf.domain.master;

import lombok.Data;

import javax.persistence.*;
import java.io.Serializable;

@Data
@Embeddable
public class LoggingEventExceptionIdentity implements Serializable {

    @ManyToOne(cascade = {CascadeType.PERSIST, CascadeType.REMOVE}, fetch = FetchType.EAGER)
    @JoinColumn(name = "event_id", nullable = false, foreignKey = @ForeignKey(name = "logging_event_exception_event_id_fkey", value = ConstraintMode.CONSTRAINT))
    private LoggingEvent loggingEvent;

    @Column(name = "i", columnDefinition = "SMALLINT", nullable = false)
    private int i;
}
